package com.example.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.example.dao.OrderDao;
import com.example.entity.Order;
import com.example.service.OrderService;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

/**
 * (Order)表服务实现类
 *
 * @author makejava
 * @since 2023-01-31 13:56:30
 */
@Service("orderService")
public class OrderServiceImpl extends ServiceImpl<OrderDao, Order> implements OrderService {

    @Override
    @Transactional
    public int add() {
        Order order = new Order();
        order.setId(1);
        order.setName("张三的订单");
        return baseMapper.insert(order);
    }
}

